package com.example.demo.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.RequestBody;

@Component
public class InstanceB {

    @Autowired
    private InstanceA instanceA;

    public void speak2(@RequestBody ScheduleRequest request){
        instanceA.speak(request);
        System.out.println("to");
    }
}
